package com.zzwc.vote.www.entity;

import com.baomidou.mybatisplus.enums.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import java.io.Serializable;

/**
 * @author weirdor
 * @since 2018-06-06
 */
@TableName("vote_territory")
public class VoteTerritory extends Model<VoteTerritory> {

    private static final long serialVersionUID = 1L;

    /**
     * 投票序号：自增
     */
	@TableId(value="id", type= IdType.AUTO)
	private Long id;
    /**
     * 投票人ip
     */
	private String ip;
    /**
     * 投票人位置
     */
	private String location;
    /**
     * 投票人的id
     */
	@TableField("user_id")
	private Long userId;
    /**
     * 投票项目名称
     */
	@TableField("enterprise_id")
	private String enterpriseId;
    /**
     * 投票时间
     */
	@TableField("vote_time")
	private Date voteTime;
	@TableField("create_time")
	private Date createTime;


	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getIp() {
		return ip;
	}

	public void setIp(String ip) {
		this.ip = ip;
	}

	public String getLocation() {
		return location;
	}

	public void setLocation(String location) {
		this.location = location;
	}

	public Long getUserId() {
		return userId;
	}

	public void setUserId(Long userId) {
		this.userId = userId;
	}

	public String getEnterpriseId() {
		return enterpriseId;
	}

	public void setEnterpriseId(String enterpriseId) {
		this.enterpriseId = enterpriseId;
	}

	public Date getVoteTime() {
		return voteTime;
	}

	public void setVoteTime(Date voteTime) {
		this.voteTime = voteTime;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "VoteTerritory{" +
			"id=" + id +
			", ip=" + ip +
			", location=" + location +
			", userId=" + userId +
			", enterpriseId=" + enterpriseId +
			", voteTime=" + voteTime +
			", createTime=" + createTime +
			"}";
	}
}
